package net.towee.server.bittorrent.impl;

import net.towee.server.bittorrent.AnnounceService.AnnounceEvent;
import net.towee.server.bittorrent.AnnounceService.AnnounceRequest;

/**
 * Implementation of announce request
 * 
 * @author c58
 */
public class AnnounceRequestImpl implements AnnounceRequest {
	private String infoHash;
	private String peerId;
	private String ip;
	private int port;
	private int upload;
	private int download;
	private AnnounceEvent event;
	private String accountId;

	public AnnounceRequestImpl(String accountId, String infoHash, String peerId, String ip, int port,
			int upl, int down, AnnounceEvent event) {
		this.infoHash = infoHash;
		this.accountId = accountId;
		this.peerId = peerId;
		this.ip = ip;
		this.port = port;
		this.upload = upl;
		this.download = down;
		this.event = event;
	}

	@Override
	public String getInfoHash() {
		return infoHash;
	}

	@Override
	public String getPeerId() {
		return peerId;
	}

	@Override
	public String getIp() {
		return ip;
	}

	@Override
	public int getPort() {
		return port;
	}

	@Override
	public long getUploaded() {
		return upload;
	}

	@Override
	public long getDownloaded() {
		return download;
	}

	@Override
	public AnnounceEvent getEvent() {
		return event;
	}

	@Override
	public String getAccountId() {
		return accountId;
	}

}